

import 'package:erp/EventBus/EventBus.dart';
import 'package:erp/global.dart';
import 'package:flutter/material.dart';

abstract class EventfulState<WIDGET extends StatefulWidget> extends State<WIDGET>{
  EventBus bus = globalBus;
  var eventIds = <int>[];
  @override
  void dispose() {
    bus.unSubscribeAllByIds(eventIds);
    super.dispose();
  }
}